package com.cntcdt.api.service.impl;

import java.util.List;

import com.cntcdt.api.db.dao.DeviceMoveApplyDao;
import com.cntcdt.api.db.model.DeviceMoveApplyModel;
import com.cntcdt.api.service.DeviceMoveApplyService;

public class DeviceMoveApplyServiceImpl implements DeviceMoveApplyService {

	@Override
	public List<DeviceMoveApplyModel> findBySortTime(int userId,int type,int sortTime) {
		return DeviceMoveApplyDao.getInstance().findBySortTime(userId,type,sortTime);
	}

	@Override
	public List<DeviceMoveApplyModel> findBySortTime(int userId, int sortTime) {
		return DeviceMoveApplyDao.getInstance().findBySortTime(userId, sortTime);
	}

	@Override
	public int inertModel(DeviceMoveApplyModel deviceMoveApply) {
		return DeviceMoveApplyDao.getInstance().insert(deviceMoveApply);
	}

	@Override
	public DeviceMoveApplyModel findById(int id) {
		return DeviceMoveApplyDao.getInstance().findByPrimaryKey(id);
	}

	@Override
	public boolean updateModel(DeviceMoveApplyModel deviceMoveApply) {
		return DeviceMoveApplyDao.getInstance().update(deviceMoveApply);
	}

	@Override
	public List<DeviceMoveApplyModel> findBySortTime(int sortTime) {
		return DeviceMoveApplyDao.getInstance().findBySortTime(sortTime);
	}

	@Override
	public List<DeviceMoveApplyModel> findBySearchContent(String searchContent) {
		return DeviceMoveApplyDao.getInstance().findBySearchContent(searchContent);
	}

}
